﻿using System.Web.Mvc;
using System.Web.UI;
using CMSMVC4.Filters;
using CMSMVC4.MultiResource;
using System.Linq;

namespace CMSMVC4.Areas.Main.Controllers
{

    public class HomeController : Controller
    {
        //
        // GET: /Home/

        [OutputCache(CacheProfile = "Cache15p")]
        public ActionResult Index()
        {
            ViewBag.Title = Resource.Title_Home;
            ViewBag.key = "3DSCAN VIỆT NAM";
            ViewBag.description = "3DSCAN VIETNAM – Nhà cung cấp dịch vụ quét và xây dựng mô hình 3D sử dụng công nghệ laser chuyên nghiệp tại Việt Nam.";
            ViewBag.Menu = 0;//danh dau menu
            return View("Index","_Layout");
        }

        [ChildActionOnly]
        public ActionResult LogoBig()
        {
            CMSMVC4Entities db = new CMSMVC4Entities();
            Baner logo = db.Baners.FirstOrDefault(x => x.Location == BanerType.LogoWeb);
            return PartialView(logo);
        }

        [ChildActionOnly]
        public ActionResult Logosmal()
        {
            CMSMVC4Entities db = new CMSMVC4Entities();
            Baner logo = db.Baners.FirstOrDefault(x => x.Location == BanerType.LogoWeb);
            return PartialView(logo);
        }

    }
}
